package cn.gson.crm.model.dao;

import cn.gson.crm.common.AttachmentType;
import cn.gson.crm.model.domain.Attachment;
import cn.gson.crm.model.domain.Member;
import org.springframework.data.repository.PagingAndSortingRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * <p>
 * ****************************************************************************
 * </p>
 * <p>
 * <b>Copyright © 2010-2017 soho team All Rights Reserved<b>
 * </p>
 * <ul style="margin:15px;">
 * <li>Description : cn.gson.crm.model.dao</li>
 * <li>Version : 1.0</li>
 * <li>Creation : 2017年07月12日</li>
 * <li>Author : 郭华</li>
 * </ul>
 * <p>
 * ****************************************************************************
 * </p>
 */
@Repository
public interface AttachmentDao extends PagingAndSortingRepository<Attachment, Long> {

	Attachment findByFilePath(String filePath);

	List<Attachment> findByFilePathIsNotAndMemberAndType(String filePath, Member member,
			AttachmentType type);

}
